{
  "coreVersion": "v1",
  "kind": "Item",
  "includeTemplates": [
    "default"
  ],
  "metadata": {
    "name": "example",
    "displayName": "Example",
    "pluralName": "examples",
    "displayPluralName": "Examples",
    "dataSource": "main",
    "tableName": "examples",
    "titleAttribute": "name",
    "description": "Examples",
    "icon": "TagOutlined",
    "core": false,
    "performDdl": false,
    "versioned": false,
    "manualVersioning": false,
    "localized": false,
    "notLockable": false
  },
  "spec": {
    "attributes": {
      "name": {
        "type": "string",
        "columnName": "name",
        "displayName": "Name",
        "description": "Name",
        "required": true,
        "unique": true,
        "indexed": false,
        "private": false,
        "length": 50
      },
      "displayName": {
        "type": "string",
        "columnName": "display_name",
        "displayName": "Display Name",
        "description": "Display Name",
        "length": 50
      },
      "description": {
        "type": "string",
        "columnName": "description",
        "displayName": "Description",
        "description": "Description",
        "length": 250
      },
      "product": {
        "type": "relation",
        "relType": "manyToOne",
        "target": "product",
        "inversedBy": "parts",
        "columnName": "product_id",
        "displayName": "Product",
        "description": "Product"
      },
      "partType": {
        "type": "enum",
        "columnName": "part_type",
        "enumSet": [
          "Assembly",
          "Part"
        ],
        "displayName": "Part Type",
        "description": "Part Type"
      },
      "ownershipType": {
        "type": "enum",
        "columnName": "ownership_type",
        "enumSet": [
          "Manufactured",
          "Borrowed",
          "Bought"
        ],
        "displayName": "Ownership Type",
        "description": "Ownership Type"
      },
      "units": {
        "type": "enum",
        "columnName": "units",
        "enumSet": [
          "pcs",
          "kg"
        ],
        "displayName": "Units",
        "description": "Units"
      },
      "cost": {
        "type": "decimal",
        "columnName": "cost",
        "displayName": "Cost",
        "description": "Cost",
        "precision": 14,
        "scale": 4,
        "minRange": 0
      },
      "weight": {
        "type": "decimal",
        "columnName": "weight",
        "displayName": "Weight",
        "description": "Weight",
        "precision": 14,
        "scale": 4,
        "minRange": 0
      },
      "releaseDate": {
        "type": "datetime",
        "columnName": "release_date",
        "displayName": "Release Date",
        "description": "Release Date"
      },
      "effectiveDate": {
        "type": "datetime",
        "columnName": "effective_date",
        "displayName": "Effective Date",
        "description": "Effective Date"
      },
      "supersededDate": {
        "type": "datetime",
        "columnName": "superseded_date",
        "displayName": "Superseded Date",
        "description": "Superseded Date"
      },
      "startSheet": {
        "type": "relation",
        "relType": "manyToOne",
        "target": "startSheet",
        "inversedBy": "parts",
        "columnName": "start_sheet_id",
        "displayName": "Start Sheet",
        "description": "Start Sheet"
      }
    },
    "indexes": {
      "examples_name_uk": {
        "columns": [
          "name"
        ],
        "unique": true
      }
    }
  }
}
